import request from '@/utils/request'

const api = {
    merchantGoodsList: '/merchantGoods/lists',
    merchantGoodsAdd: '/merchantGoods/add',
    merchantGoodsEdit: '/merchantGoods/edit',
    merchantGoodsDel: '/merchantGoods/delete',
    merchantGoodsOrderList: '/merchantGoodsOrder/lists',
    merchantGoodsOrderDetail: '/merchantGoodsOrder/detail',
    merchantGoodsOrderSend: '/merchantGoodsOrder/sendOut',
    merchantGoodsOrderSendEdit: '/merchantGoodsOrder/sendOutEdit'
}

export function merchantGoodsOrderSendEdit (parameter) {
    return request({
        url: api.merchantGoodsOrderSendEdit,
        method: 'get',
        params: parameter
    })
}

export function merchantGoodsOrderSend (parameter) {
    return request({
        url: api.merchantGoodsOrderSend,
        method: 'get',
        params: parameter
    })
}

export function merchantGoodsOrderDetail (parameter) {
    return request({
        url: api.merchantGoodsOrderDetail,
        method: 'get',
        params: parameter
    })
}

export function merchantGoodsOrderList (parameter) {
    return request({
        url: api.merchantGoodsOrderList,
        method: 'get',
        params: parameter
    })
}

export function merchantGoodsDel (parameter) {
    return request({
        url: api.merchantGoodsDel,
        method: 'get',
        params: parameter
    })
}

export function merchantGoodsEdit (parameter) {
    return request({
        url: api.merchantGoodsEdit,
        method: 'post',
        data: parameter
    })
}

export function merchantGoodsAdd (parameter) {
    return request({
        url: api.merchantGoodsAdd,
        method: 'post',
        data: parameter
    })
}

export function merchantGoodsList (parameter) {
    return request({
        url: api.merchantGoodsList,
        method: 'get',
        params: parameter
    })
}
